package xiaohuo.fancyring.listener

import org.bukkit.event.player.PlayerQuitEvent
import taboolib.common.platform.event.SubscribeEvent
import taboolib.module.lang.event.PlayerSelectLocaleEvent
import xiaohuo.fancyring.util.closeRealBody
import xiaohuo.fancyring.util.closeRing

object Players {
    @SubscribeEvent
    fun onQuit(event: PlayerQuitEvent) {
        event.player.closeRing()
        event.player.closeRealBody()
    }

    @SubscribeEvent
    fun onSelectLocale(event: PlayerSelectLocaleEvent) {
        event.locale = "zh_CN"
    }
}